<?php

namespace App\Http\Requests;

use App\Http\Requests\Request;

class FenxiaoRequest extends Request
{
        /**
     * Determine if the user is authorized to make this request.
     *
     * @return bool
     */
    public function authorize()
    {
        return true;
    }

    /**
     * Get the validation rules that apply to the request.
     *
     * @return array
     */
    public function rules()
    {
        return [
            're_code_1'=>'required | numeric',
            're_money_business'=>'required | numeric',
            're_money_1'=>'required | numeric',
            're_money_2'=>'required | numeric',
            're_money_3'=>'required | numeric',
            're_money_4'=>'required | numeric',
            're_money_5'=>'required | numeric',
            'money_1'=>'required | numeric',
            'money_2'=>'required | numeric',
            'money_3'=>'required | numeric',
            'money_4'=>'required | numeric',
            'money_5'=>'required | numeric'
        ];
    }
    public function messages(){
        return [
            're_code_1.required'=>'积分返回比例不能为空',
            're_code_1.numeric'=>'积分返回比例必须是数字',
            're_money_business.required'=>'分销商返钱比例不能为空',
            're_money_business.numeric'=>'分销商返钱比例必须是数字',
            're_money_1.required'=>'一级分销比例不能为空',
            're_money_1.numeric'=>'一级分销比例必须是数字',
            're_money_2.required'=>'二级分销比例不能为空',
            're_money_2.numeric'=>'二级分销比例必须是数字',
            're_money_3.required'=>'三级分销比例不能为空',
            're_money_3.numeric'=>'三级分销比例必须是数字',
            're_money_4.required'=>'四级分销比例不能为空',
            're_money_4.numeric'=>'级分销比例必须是数字',
            're_money_5.required'=>'五级分销比例不能为空',
            're_money_5.numeric'=>'五级分销比例必须是数字',
            'money_1.required'=>'一级分销金额不能为空',
            'money_1.numeric'=>'一级分销金额必须是数字',
            'money_2.required'=>'二级分销金额不能为空',
            'money_2.numeric'=>'二级分销金额必须是数字',
            'money_3.required'=>'三级分销金额不能为空',
            'money_3.numeric'=>'三级分销金额必须是数字',
            'money_4.required'=>'四级分销金额不能为空',
            'money_4.numeric'=>'四级分销金额必须是数字',
            'money_5.required'=>'五级分销金额不能为空',
            'money_5.numeric'=>'五级分销金额必须是数字'
        ];
    }
}